home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Visual Basic Source Code
/
Visual Basic Source Code.iso
/
vbsource
/
shuffle
/
cd.bas
< prev
next >
Wrap
BASIC Source File
|
1995-10-23
|
2KB
|
57 lines
'============================================
' SHUFFLE CD PLAYER EXAMPLE
' Copyright(c) 1994 Larry Robert Seater
'============================================
' Disclaimer of Warranty:
' This software and the accompanying files are 'as is'
' and without warranties as to performance of the
' software and the accompanying files or any other
' warranties whether expressed or implied.
' No warranty of fitness for a particular purpose
' is offered.
'
' You may not sell this software or it's source code.
' You may use this code in any way you find useful.
' Enough said!
'
' This is an example of some things I've learned
' about the MCI.VBX custom control from the Visual
' Basic Professional Edition. This is written in
' VB Pro 3.0 and needs to be run (I think) on the
' same. There may be a few bugs, but I knocked it
' out in a couple of hours. There are a few other
' tricks(?) in the code too.
'
' Please if you have any comments (good or bad) or
' any suggestions, or want to trade code write me or
' E-Mail me at:
' AOL: LarryS8302
'
' Land Mail: Larry Seater
' 2124 NE 36th Av.
' Portland, OR 97212
'
' Thanks!
' Force all runtime errors to be handled here.
Sub DisplayErrorMessageBox ()
Select Case Err
Case MCIERR_CANNOT_LOAD_DRIVER
Msg$ = "Error load media device driver."
Case MCIERR_DEVICE_OPEN
Msg$ = "The device is not open or is not known."
Case MCIERR_INVALID_DEVICE_ID
Msg$ = "Invalid device ID."
Case MCIERR_INVALID_FILE
Msg$ = "Invalid filename."
Case MCIERR_UNSUPPORTED_FUNCTION
Msg$ = "Action not available for this device."
Case Else
Msg$ = "Unknown Error (" + Str$(Err) + ")."
End Select
MsgBox Msg$, 48, MCI_APP_TITLE
End Sub